package com.eastcom.providor.service.impl;

import java.util.List;

import com.eastcom.bm.atom.Atom_ActionRule;
import com.eastcom.providor.dao.IActionRuleDao;
import com.eastcom.providor.service.BaseService;
import com.eastcom.providor.service.IActionRuleService;

public class ActionRuleService extends BaseService implements IActionRuleService {

	private IActionRuleDao actionRuleDao;
	
	public void setActionRuleDao(IActionRuleDao actionRuleDao) {
		this.actionRuleDao = actionRuleDao;
	}

	public Atom_ActionRule getActionRuleByDataSetId(String datasetId) {
		try {
			return actionRuleDao.getActionRuleByDataSetId(datasetId);
		} 
		catch (Exception e) {
			log.error("ActionRuleService getActionRuleByDataSetId error", e);
			e.printStackTrace();
		}
		return null;
	}

	public List<Atom_ActionRule> getAllActionRule() {
		try {
			return actionRuleDao.getAllActionRule();
		} 
		catch (Exception e) {
			log.error("ActionRuleService getAllActionRule error", e);
			e.printStackTrace();
		}
		return null;
	}

}
